<?php if(isset($aRaovats_sidebar) && count($aRaovats_sidebar)>0) { ?>
<div id="module-sticky-top">
    <h2 class="title"><?php echo isset($sidebar_title)?$sidebar_title:'Rao vặt'; ?></h2>
    <a class="view-more" href="<?php echo page_url(RAOVAT_SLUG); ?>">Xem tất cả <i class="fa fa-sort-alpha-asc"></i></a>
    <div class="sticky-top-list"><!--category-productsr-->
        <ul class="nav nav-pills nav-stacked">
            <?php foreach($aRaovats_sidebar as $r) { ?>
            <li class="sticky-top-item">
                <a class="item-title" title="<?php echo $r->title; ?>" href="<?php echo rao_vat_single_url($r->slug); ?>"><?php echo $r->title; ?></a>
                <div class="item-left pull-left mgl5 mgr5">
                    <?php
                        if($r->getImage()!=''){
                            $img = upload('public/'.$r->image_folder.'/'.RAOVAT_IMAGE_URL.$r->getImage());
                    ?>
                    <a title="<?php echo $r->title; ?>" href="<?php echo rao_vat_single_url($r->slug); ?>">
                        <img title="<?php echo $r->getTitle(); ?>" src="<?php echo $img ?>" width="64" alt="<?php echo $r->getTitle(); ?>" />
                    </a>
                    <?php
                        }
                    ?>
                </div>
                <div class="item-right">
                    <?php
                        $des = strlen($r->description) > 100 ? substr($r->description, 0, 100).' ...' : $r->description;
                    ?>
                    <small class='description text-hyphens'><?php echo $des; ?></small>
                </div>
                <div class="clearfix mgbt5"></div>
            </li>
            <?php } ?>
        </ul>
    </div><!--/category-products-->
</div>

<?php } ?>